package zl.service;

import com.github.pagehelper.PageInfo;
import zl.bean.Category;
import zl.bean.Novel;

import java.sql.SQLException;
import java.util.List;


public interface NovelService {
    int addNovel(Novel novel);

    int deleteNovel(Integer id);

    int updateNovel(Novel novel);

    //分页查询
    PageInfo<Novel> selectByPage(int currentPage, String keyword) throws SQLException;

    //查询所有小说类型
    List<Category> selectAllCategory();

    //根据id查小说
    Novel selectById(Integer id);

    List<Novel> selectAllNovel();
}
